#include "../../client/Rpc_client.hpp"

int main()
{
    auto topic_client = std::make_shared<ns_rpc_client::TopicClient>("127.0.0.1", 8080);
    bool ret = topic_client->Create("new");
    if (ret == false)
        LOG(ERROR, "创建new主题失败");

    for (int i = 1; i <= 10; i++)
    {
        std::string msg = "you have a new new: " + std::to_string(i);
        topic_client->Publish("new", msg);
    }
    topic_client->Shutdown();
    return 0;
}